#ifndef tmButton_h__
#define tmButton_h__

#include "./tmInclude.h"
#include "./tmControl.h"
#include "./tmAnimation.h"

class tmButton : public tmControl
{
	SetGetProperty(Pressed,bool,_bPressed);
	public:
		tmButton():_bPressed(false){}
		GLES::Bool createFrom(char* nameNormal,char* namePressed,GLES::PointI& point,GLES::SizeI* size  = NULL,GLES::RectI* pictRect = NULL);
		virtual VOID draw(GLES::Painter* painter,GLES::RectI* parent = NULL);
		virtual VOID onPressed(int x,int y);
		virtual VOID onPressRelease(int x,int y);
	private:
		GLES::Pict _btnNormal;
		GLES::Pict _btnPressed;
};
#endif // tmButton_h__